package de.tum.in.eist.poll.shared;

import java.io.Serializable;

@SuppressWarnings("serial")
/**
 * Representation of a student's opinion on a particular lecture.
 * 
 */
public class Feedback implements Serializable {

	/** Overall satisfaction represented by an integer ranging from 1 to 5.*/
	private int satisfaction;
	/** Aspects of the lecture the student found positive.*/
	private String like;
	/** Aspects of the lecture the student found negative.*/
	private String dislike;
	/** The rated lecture's identification number as stored in the database's lectures table.*/
	private int lectureid = -1;

	/**
	 * Default constructor.
	 * 
	 * @deprecated Empty Feedback objects should be avoided.
	 */
	public Feedback() {
		satisfaction = 0;
		like = "";
		dislike = "";
	}

	/**
	 * Full constructor. All values have to be set at creation.
	 */
	public Feedback(int satisfaction, String like, String dislike, int lectureid) {
		this.satisfaction = satisfaction;
		this.like = like;
		this.dislike = dislike;
		this.lectureid = lectureid;
	}

	/**
	 *@return A student's opinion on a particular lecture.
	 */
	public int getSatisfaction() {
		return satisfaction;
	}

	/**
	 *@return The rated lecture's identification number as stored in the database's lectures table.
	 */
	public int getLectureID() {
		return lectureid;
	}

	/**
	 *@return Aspects of the lecture the student found positive.
	 */
	public String getLike() {
		return like;
	}

	/**
	 *@return Aspects of the lecture the student found negative.
	 */
	public String getDislike() {
		return dislike;
	}
}
